Skip to content

feat: add rainbow wave animation to progress bar#28

Open
AurelianoBR wants to merge 4 commits intoglauberlima:mainfrom
AurelianoBR:feat/rainbow-wave-progress-bar
Open

feat: add rainbow wave animation to progress bar#28
AurelianoBR wants to merge 4 commits intoglauberlima:mainfrom
AurelianoBR:feat/rainbow-wave-progress-bar

Conversation

@AurelianoBR
Copy link
Copy Markdown

@AurelianoBR AurelianoBR commented Apr 14, 2026

Summary

  • Add rainbow wave animation to the context usage progress bar using 256-color palette cycling
  • Make rainbow wave configurable via SHOW_RAINBOW_WAVE toggle (enabled by default)
  • Integrate toggle into install.sh feature selection menu and patch-statusline.sh patching system
  • When disabled, falls back to the original tier-based color coding (green → cyan → orange → red)
  • Fix shellcheck SC2250 and SC2310 violations (function calls in conditional contexts)

Changes

  • statusline.sh: Add WAVE_COLORS array, SHOW_RAINBOW_WAVE config flag, and conditional rendering in build_progress_bar(). Isolate is_present() calls from conditional contexts to satisfy SC2310.
  • patch-statusline.sh: Support --no-rainbow-wave flag and include SHOW_RAINBOW_WAVE in config block patching.
  • install.sh: Add rainbow-wave to component selection menu (7 options, up from 4). Default selection includes all features.

Test plan

  • Run ./tests/unit.sh && ./tests/integration.sh && ./tests/shellcheck.sh — all pass
  • Test with SHOW_RAINBOW_WAVE=true — verify rainbow colors cycle through filled blocks
  • Test with SHOW_RAINBOW_WAVE=false — verify fallback to tier-based solid colors
  • Test ./patch-statusline.sh statusline.sh --no-rainbow-wave patches correctly
  • Test ./install.sh — verify new menu options work for all 7 selections

🤖 Generated with Claude Code

AurelianoBR and others added 4 commits April 14, 2026 13:57
Replace static tier-based coloring with a per-character rainbow wave
using ANSI 256-color codes. Each filled block gets a different color
from a 12-color palette, and the phase shifts once per second based
on epoch time, creating a flowing wave effect across invocations.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- SC2250: add braces around $color_idx and $_v variable references
- SC2310: extract is_present/validate_directory calls from if conditions
  to avoid set -e being disabled inside conditionals

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Use `|| rc=$?` pattern to capture return codes outside any conditional
chain, satisfying shellcheck SC2310 which warns about set -e being
disabled inside if/&& conditions.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add SHOW_RAINBOW_WAVE toggle to the config patching system, allowing
users to opt-out of rainbow wave animation during installation. When
disabled, falls back to tier-based color coding for the progress bar.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant